<?php
class InstructorCurso extends AppModel {
	var $name = 'InstructorCurso';
	var $useTable = 'instructores_cursos';
	var $validate = array(
		'id' => array(
			'blank' => array(
				'rule' => array('blank'),
				'on' => 'create' 
			)
		),
		'curso_id' => array(
			'notEmpty' => array(
				'rule' => array('notEmpty')
			),
			'numeric' => array(
				'rule' => array('numeric')
			)
		),
		'persona_id' => array(
			'notEmpty' => array(
				'rule' => array('notEmpty')
			),
			'numeric' => array(
				'rule' => array('numeric')
			)
		),
		'quieredictarcurso' => array(
			'boolean' => array(
				'rule' => array('boolean')
			),
			'notEmpty' => array(
				'rule' => array('notEmpty')
			)
		),
		'razon_id' => array(
			'numeric' => array(
				'rule' => array('numeric')
			)
		),
		'diaspreparar' => array(
			'numeric' => array(
				'rule' => array('numeric')
			)
		),
		'pagohoraesp' => array(
			'decimal' => array(
				'rule' => array('decimal')
			)
		),
		'conocimiento' => array(
			'numeric' => array(
				'rule' => array('numeric')
			)
		),
		'observaciones' => array(
			'maxlength' => array(
				'rule' => array('maxLength', '255')
			)
		)
	);

	var $belongsTo = array(
		'Curso' => array(
			'className' => 'Curso',
			'foreignKey' => 'curso_id'
		),
		'Persona' => array(
			'className' => 'Persona',
			'foreignKey' => 'persona_id'
		),
		'Razon' => array(
			'className' => 'Razon',
			'foreignKey' => 'razon_id'
		)
	);
}
?>